American patent U.S. Pat. No. 5,754,707 describes an undithering method to convert a dithered representation of an image into a continuous tone representation of the image. The method compares regions of the dithered image with sections of dither patterns. When such a pattern is found, the corresponding part of the image is converted into the appropriate continuous tone representation. The regions of the dithered image may be formed by applying windows.
American patent U.S. Pat. No. 5,598,184 describes a method and apparatus for improved color recovery in a computer graphics system, in which color information lost due to encoding data by dithering is recovered by passing the encoded data through a filter that has the same effective shape and size as the dither matrix used to encode the data. Using this method, N bits of color information is recoverable from a data stream that has been dithered using a dither matrix of 2N cells. This patent also discloses the manner in which a data stream representing an image is dithered, leading to a chessboard pattern in the resulting dithered data stream. For both the dither and undither method, the same number of pixels in the data stream are compared.
American patent U.S. Pat. No. 5,164,717 describes a method and apparatus for dithering of anti-aliased vectors. Dithered images are composited with separately undithered images. This method is specifically applied to the rendering of lines on computer graphic display devices. A vector to be displayed is first anti-aliased at a first resolution and is then composited with the corresponding background pixels of the digital image. Then, the pixel data output of the compositing process is dithered to a lower resolution for storage and display.
Thus far, no general methods or apparatus has been disclosed which can be used to perform both general dithering and undithering functions. Usually, for every application a dedicated dither function is implemented in either hardware or software, as well as a dedicated undither function.
An object of the present invention is to provide a method and apparatus for processing a data word in a data stream, such as a data stream representing a digital image, which is suitable to provide both a dithering and an undithering function. The present invention should provide a single interface between existing different data sizes (8-to-9, 5-to-8, 6-to-8 or 9-to-8 bits data sizes) in data streams, such as data streams representing a digital image. This will cover all the currently popular data sizes.
A secondary object of the present invention is to provide a dither function in which dithering is applied only to uniform and constant value parts of the data stream, in order to prevent distortion of edges or details.